/**
 * 双链表带哨兵
 *
 * @author 86155
 * @date 2023/11/04
 */
public class DoubleLinkedListSentinel {
    private final Node head;
    private final Node tail;

    public DoubleLinkedListSentinel() {
        head = new Node(null,null,666);
        tail = new Node(null,null,888);
        head.prev = tail;
        tail.next = head;
    }


    /**
     * 节点
     *
     * @author 86155
     * @date 2023/11/04
     */
    static class Node{
        Node next;
        Node prev;
        int value;

        public Node(Node next, Node prev, int value) {
            this.next = next;
            this.prev = prev;
            this.value = value;
        }
    }

}
